<?php
session_start();
$a = array();
if(isset($_SESSION['loggedUsername'])){
    $a['code'] = 1;
    $a['username'] = $_SESSION['loggedUsername'];
    $a['pic'] = $_SESSION['pic'];
}
else{
    $a['code'] = -1;
}
echo json_encode($a);
